﻿<%@ Page Title="" Language="C#" AutoEventWireup="true" CodeBehind="DisplayRevisionFiles.aspx.cs" Inherits="CodeDemon.Views.Builder.DisplayRevisionFiles" %>


<% var rev = (from revs in ViewData.Model.DAO.GetSVNLogByLogID(ViewData.Model.CurrentRevisionNumber) select revs).FirstOrDefault();

   System.Xml.XmlReader xRead = System.Xml.XmlReader.Create(new System.IO.StringReader(rev.LogXml));
   System.Xml.Linq.XDocument xDoc = System.Xml.Linq.XDocument.Load(xRead);

   foreach (var f in xDoc.Descendants( "path" ))
   {
%>

      <li class="changesetfilepath">
         <%= f.Value %>
         <% if (f.Attribute("action").Value == "M") { %>
             <span class="filestatus">Modified</span>
         <% } %>
         <% if (f.Attribute("action").Value == "D") { %>
             <span class="filestatus">Deleted</span>
         <% } %>
         <% if (f.Attribute("action").Value == "A") { %>
             <span class="filestatus">Added</span>
         <% } %>                           
         &nbsp; <a href="<%=ConfigurationManager.AppSettings["FishEyeRepoLookupURL"] %><%=f.Value %>#r<%=rev.Revision %>"><img src="/CodeDemon/Content/icn_history.gif" border="0" /></a> 
         &nbsp; <a href="<%=ConfigurationManager.AppSettings["FishEyeRepoLookupURL"] %><%=f.Value %>?r=<%=rev.Revision %>"><img src="/CodeDemon/Content/icn_annotation.gif" border="0" /></a>     
      </li> 
<% }  %>